package com.wjpeng.wms.domain;

import lombok.Getter;
import lombok.Setter;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;

@Setter @Getter
public class StockIncomeBill {
    public static final Integer NORMAL = 1;//未审核状态
    public static final Integer AUDIT = 2;//已审核状态

    private Long id;
    private String sn;//采购单号
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date vdate;//业务时间
    private Integer status = NORMAL;//单据状态
    private BigDecimal totalAmount;//采购总额
    private BigDecimal totalNumber;//采购总数量
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date auditTime;//审核状态
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    private Date inputTime;//录入状态

    private Employee inputUser;//录入人
    private Employee auditor;//审核人
    private Depot depot;//仓库


    //包含的采购明细 组合关系
    private List<StockIncomeBillItem> items = new ArrayList<>();

}